public class Test {
    public static void main(String[] args) {
        MyBinarySearchTree myBinarySearchTree = new MyBinarySearchTree();
        int[] arr = {2,6,4,7,7,8,2,9,1,3,5};
        for (int i = 0; i < arr.length; i++) {
            myBinarySearchTree.insert(arr[i]);
        }
        myBinarySearchTree.ergodic(myBinarySearchTree.root);
        System.out.println();
        myBinarySearchTree.remove(4);
        System.out.println();
        myBinarySearchTree.ergodic(myBinarySearchTree.root);
    }
}
